var nodes = document.getElementsByTagName("script");
var inlineScript = [], externalScript=[];
for(var i=0;i<nodes.length;i++){
    var node = nodes[i];
    if(node.src){
        externalScript.push(node.src);
    }else{
        inlineScript.push(node.innerText);
    }
}
chrome.extension.sendRequest({
        url:location.href, 
        inlineScript:inlineScript, 
        externalScript:externalScript
    }, 
    function(resp){
        console.log("send data to  bakcground page from " + resp.url);
});
